package org.example.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class TestDemoController {
    @GetMapping("test")
    public String test(String name){
        System.out.println("test......");
        if (name!=null&&name.equals("xxx")){
            int i=1/0;
        }
        return "test......";
    }
    @GetMapping("test1")
    public String test1(String name){

        try {
            System.out.println("test1......");
            Thread.sleep(1000);
        } catch (Exception e) {
            e.printStackTrace();
        }
        return "test1......";
    }
    @GetMapping("test2")
    public String test2(String name){


        System.out.println("test2......");

        return "test2......";
    }
}
